/**
 *     This file is part of cesm-ws.
 *
 *     cesm-ws, Web Service for Community Earth System Model
 *
 *     Copyright (c) 2010, Purdue University and/or affilicates or thrid-party contributors as
 *     indicated by the @author tags or express copyright attribution statements
 *     applied by the authors. All third-party contributions are distributed under
 *     license by Purdue University.
 *
 *     cesm-ws is free software: you can redistribute it and/or modify
 *     it under the terms of the GNU General Public License as published by
 *     the Free Software Foundation, either version 3 of the License, or
 *     (at your option) any later version.
 *
 *     This program is distributed in the hope that it will be useful,
 *     but WITHOUT ANY WARRANTY; without even the implied warranty of
 *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *     GNU General Public License for more details.
 *
 *     You should have received a copy of the GNU Lesser General Public License
 *     along with this distribution.  If not, see <http://www.gnu.org/licenses/>.
 */

package edu.purdue.rcac.cesm.facade.bean;

import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlAttribute;
import javax.xml.bind.annotation.XmlRootElement;

import edu.purdue.rcac.cesm.persistence.model.CESMCaseRuntime;

@XmlRootElement(name = "runtime")
@XmlAccessorType(XmlAccessType.FIELD)
public class CaseRuntime {

	@XmlAttribute(name = "job-status", namespace = "")
	private String jobStatus;
	@XmlAttribute(name = "pbs-id", namespace = "")
	private String pbsid;
	@XmlAttribute(name = "start-time", namespace = "")
	private String startTime;
	@XmlAttribute(name = "used-wall-time", namespace = "")
	private String usedWallTime;
	@XmlAttribute(name = "used-cpu-time", namespace = "")
	private String usedCPUTime;
	@XmlAttribute(name = "queue", namespace = "")
	private String queue;

	public CaseRuntime(CESMCaseRuntime caseRuntime) {
		this.jobStatus = caseRuntime.getJobStatus().toString();
		this.pbsid = caseRuntime.getPbsid();
		this.startTime = caseRuntime.getStartTime().toString();
		this.usedCPUTime = caseRuntime.getUsedCPUTime();
		this.usedWallTime = caseRuntime.getUsedWallTime();
		this.queue = caseRuntime.getQueue();
	}

	public CaseRuntime() {
		super();
	}

	public String getJobStatus() {
		return jobStatus;
	}

	public void setJobStatus(String jobStatus) {
		this.jobStatus = jobStatus;
	}

	public String getPbsid() {
		return pbsid;
	}

	public void setPbsid(String pbsid) {
		this.pbsid = pbsid;
	}

	public String getStartTime() {
		return startTime;
	}

	public void setStartTime(String startTime) {
		this.startTime = startTime;
	}

	public String getUsedWallTime() {
		return usedWallTime;
	}

	public void setUsedWallTime(String usedWallTime) {
		this.usedWallTime = usedWallTime;
	}

	public String getUsedCPUTime() {
		return usedCPUTime;
	}

	public void setUsedCPUTime(String usedCPUTime) {
		this.usedCPUTime = usedCPUTime;
	}

	public String getQueue() {
		return queue;
	}

	public void setQueue(String queue) {
		this.queue = queue;
	}

}
